<template>
  <div class="hot-sale">
    <div class="title">
      <span>周末去哪儿</span>
    </div>
    <ul>
      <li v-for="item in list" :key="item.id">
        <div class="picture">
          <img :src="item.imgUrl" alt />
        </div>
        <div class="content">
          <p class="content-title">{{item.title}}</p>
          <p class="content-state">{{item.desc}}</p>
          <button class="details">查看详情</button>
        </div>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: 'Weekend',
  props: {
    list: {
      type: Array
    }
  }
}
</script>

<style lang="stylus" scoped>
li
  overflow: hidden
.title
  height: 0.68rem
  background-color: #eee
  line-height: 0.68rem
  text-indent: 0.2rem
  font-weight: bold
  margin: 0.1rem 0
.picture
  // float: left
  width: 100%
  height: 1.8rem
  margin-bottom: 1rem
  img
    width: 100%
.content
  padding: 0.2rem
  .content-title
    font-weight: bold
    margin-bottom: 0.1rem
  .content-state
    color: #aaa
    margin-bottom: 0.1rem
  .details
    background-color: #ff9300
    padding: 0.1rem 0.2rem
    font-size: 0.2rem
    border-radius: 0.1rem
    color: #fff
    font-weight: bold
</style>
